(provide 'global)

;;---------------------------------------------------------------------------
(require 'custom-dired)
;;(require 'top-mode)

;; ibuffer
(global-set-key (kbd "C-x C-b") 'ibuffer)
(autoload 'ibuffer "ibuffer" "List buffers." t)

;; ido
;; http://www.emacswiki.org/emacs/InteractivelyDoThings
(ido-mode t)
(setq ido-enable-flex-matching t) ;; enable fuzzy matching
(setq ido-ignore-files 
    (append ido-ignore-files '(".pyc", ".orig", "~", ".swp")))

;; turn off color-theme on terminal frame

;;others
(fset 'yes-or-no-p 'y-or-n-p)
(display-time)
(setq display-time-24hr-format t)
(setq inhibit-startup-message t)
(toggle-truncate-lines)

(scroll-bar-mode -1)
(tool-bar-mode -1)
(menu-bar-mode -1)

(when window-system 
	(require 'color-theme)
	(eval-after-load "color-theme"
		'(progn (color-theme-initialize)
			(color-theme-blackboard)))
	(set-face-attribute 'default nil :height 180)
)

(setq window-system-default-frame-alist
    '(
        ;; if frame created on x display
        (x
		;; mouse
		(mouse-wheel-mode . 1)
		(mouse-wheel-follow-mouse . t)
		(mouse-avoidance-mode . 'exile)
		;; face
		(setq x-select-enable-clipboard t)
        )
        ;; if on term
        (nil
            ;;(menu-bar-lines . 0) (tool-bar-lines . 0)
        )
    )
)
